<?php get_header(); ?>

<div class="main">

  <div class="page_product">
    <div class="am-container">
      <ul class="am-nav am-nav-pills">
    	  <?php foreach(get_product_category() as $cat): ?>
            <li><a href="#"><?php echo $cat->name; ?></a></li>
    	  <?php endforeach; ?>
      </ul>
      <!-- 产品列表开始 -->

	  <?php if ( have_posts() ) : ?>

      <ul class="md-block-grid-4 sm-block-grid-2 product_list">

	  <?php while ( have_posts() ) : the_post(); ?>
        <li>
          <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('post-thumbnail-315-219'); ?></a>
          <div class="title am-g am-g-collapse">
            <div class="am-u-md-12">
              <h4><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h4>
              <p class="am-text-sm author">作者 <span class="am-text-primary"><?php the_author(); ?></span></p>
            </div>
          </div>
          <div class="con am-g">
            <p class="am-text-sm am-u-md-12"><?php the_excerpt(); ?></p>
          </div>
        </li>
	  <?php endwhile; ?>

      </ul>

	  <?php endif; ?>
      <!-- 产品列表结束 -->
        <!-- 分页 -->
        <?php if ( function_exists( 'wpdx_paging_nav' ) ) { wpdx_paging_nav(); } ?>
        <!-- 分页结束 -->
    </div>
  </div>   
</div>

<?php get_footer(); ?>